;xxxxxxxxxxxxx Ask Whether To Start New Site xxxxxxxxxxxxxxxxxxxxxxxx
; try to open the recent project
GOSUB CommonInit
IF nRightOuts = 999
GOSUB AskForNoWiz
ENDIF
OPENPROJECT "" ;close out any open project
IF fileexists( lastProject ) = "Yes"
OPENPROJECT lastProject
ENDIF
SETTEMP makeNewSite = "No"
LOADVARIABLES
ARGUMENT changeextension( lastProject "VAR" )
SETTEMP pr_modify = "&Modify the ",familyLastName," site"
SETTEMP pr_new = "&Start a new Web site"
SETTEMP pr_pick = "&Choose a site to modify"
SETTEMP tx_modify = "\n MAKE CHANGES\n\nChoose this to make modifications to the ",familyLastName," family Web site you previously created.\n\nYou can add or change sections, and make other changes."
SETTEMP tx_new = "\n START A NEW SITE\n\nChoose this option to start a new family Web site.\n\nUse this if you want to make a fresh start on your own Web site, or if you want to create a new site for someone else."
SETTEMP tx_pick = "\n\n PICK A SITE TO CHANGE\nThis option displays a list of family names and photos so that you can pick a different site to work on.\n\nYou presently have ",nFamilies," Web sites to pick from."
SETTEMP sys_chgtx = "\n MAKE SETTING CHANGES\n\nThis option permits you to change settings that control the behavior of the wizard.\n\nProceed with caution if you choose this item!"
SETTEMP sys_chg = "Modify &wizard settings"
GOTO BeginSelections
[BeginSelections]
IF ProjectExists = "Yes" ;a site is open
STARTWIZARD
IF nFamilies < 2 ;they have one previous site
; a project already exists
BACKSTOP
PAGE
NAME makeNewSite
WIZPIC wizpics\wizchoz2.gif
DESCRIPTION_RE "You have previously created a family Web site for the ",familyLastName," family. Would you like to make modifications to the site or would you like to start over and create a new Web site?"
TYPE RADIOBUTTONSWITHTEXT
DEFAULT No
ARGUMENT pr_modify@No@tx_modify
ARGUMENT pr_new@Yes@tx_new
ARGUMENT sys_chg@Sys@sys_chgtx
ELSE
;have several previous sites and a project is open
BACKSTOP
PAGE
NAME makeNewSite
WIZPIC wizpics\wizchoz2.gif
DESCRIPTION_RE "You have previously created ",nFamilies," Web sites. The ",familyLastName," family site was worked on most recently and is now open.\n\nWould you like to make modifications to the site that is open, preview or publish it, choose a different site to work on, or create a new Web site?"
TYPE RADIOBUTTONSWITHTEXT
DEFAULT No
ARGUMENT pr_modify@No@tx_modify
ARGUMENT "Pre&view this Web site in your browser"@Preview@"PREVIEW in the BROWSER\n\nWant to see how your Web site will look on the Internet?\n\nThe wizard will create HTML files from your Web site information and then load your browser and let you see what the site will look like on the Net. The files remain on your computer."
ARGUMENT "P&ublish this Web site (upload files to the Net)"@Publish@"\n PUBLISH THE WEB SITE\n\nAre you ready to put the family Web site out onto the Net?\n\nChoose this item to upload the files for your Web site directly to the Internet."
ARGUMENT pr_new@Yes@tx_new
ARGUMENT pr_pick@Pick@tx_pick
ARGUMENT sys_chg@Sys@sys_chgtx
ENDIF
ELSE
IF nFamilies > 1 ;they have several previous sites
STARTWIZARD
BACKSTOP
PAGE
NAME makeNewSite
WIZPIC wizpics\filewiz.gif
DESCRIPTION_RE "You have previously created ",nFamilies," family Web sites. Would you like to pick one of the existing Web sites and make modifications or would you like to start a new Web site?"
TYPE RADIOBUTTONSWITHTEXT
DEFAULT Pick
ARGUMENT pr_pick@Pick@tx_pick
ARGUMENT pr_new@Yes@tx_new
ARGUMENT sys_chg@Sys@sys_chgtx
ELSE ;no previous sites
SETTEMP makeNewSite = "Yes"
ENDIF
ENDIF
IF makeNewSite = "Sys"
GOSUB ClearOuts
GOSUB ModifyUserSettings
SAVEVARIABLES
ARGUMENT changeextension( ProjectFile "VAR" )
SETTEMP makeNewSite = "No"
GOTO BeginSelections
ENDIF
IF makeNewSite = "Yes"
GOSUB ClearOuts
; close the current project, we're going to make a new one
OPENPROJECT ""
STOPWIZARD
; this is a script for a brand new site
RUNSCRIPT "scripts\new_site.dat"
ENDIF
IF MakeNewSite = "Preview"
GOSUB ClearOuts
BUSY 1
ARGUMENT "Wait just a moment as the wizard prepares files for your browser. Then, the wizard will launch your Browser program. You may need to maximize your browser program when it starts."
PREVIEW
BUSY 0
STOPWIZARD
RUNSCRIPT "ww.dat" ;restart this one
ENDIF
IF MakeNewSite = "Publish"
GOSUB ClearOuts
LOADVARIABLES
ARGUMENT changeextension( ProjectFile "VAR" )
;
IF hasGatheredFTPInfo <> "Yes"
SETTEMP no_skipping = "Yes"
GOSUB ServerBegin
ENDIF
SETTEMP pub_description = "Before you can publish the files to the Internet, you must have your Internet connection active. This means that you computer must be connected to the Internet through your modem.\n\nIf your computer is already connected to the Internet, press the Next button to continue. If it is not connected, they make the connection first, and then press the Next button to continue.\n\nTo activate your Internet connection, "
IF Windows95 = "No"
SETTEMP pub_description = pub_description," press Alt+Tab or Ctrl+Esc to access the Windows task manager or Program manager."
ELSE
SETTEMP pub_description = pub_description," press Alt+Tab to switch to a different program or open folder or press Ctrl+Esc to bring up the Start button list."
ENDIF
SETTEMP pub_description = pub_description,"\n\nThen, you can activate your Internet connection and proceed."
BACKSTOP
PAGE
WIZPIC wizpics\wizcast2.gif
TYPE DESCRIPTION
NAME pub_description
DESCRIPTION_RE pub_description
BUSY 1
ARGUMENT "Before the Web site can be published, the wizard must construct HTML files that are used on the Internet. This could take a moment or two. Please be patient."
; test for existance of the family sites; compress array as necessary
SETTEMP familyNumber = 1
STARTWIZARD
PAGE
WIZPIC wizpics\filewiz.gif
NAME familyNumber
TYPE LIST
DESCRIPTION Pick the family Web site that you wish to change from the list shown below.\n\nWhen you highlight the family name, the family photo will be shown to help you decide if this is the correct site.
SETTEMP thisFamName = arrayelement( FamNameList n )
SETTEMP thisHPJFile = arrayelement( ProjNameList n )
SETTEMP thisPhoto = arrayelement( FamPhotoList n )
IF fileexists( thisHPJFile ) = "No"
; remove element n from the three arrays
SETTEMP m = add( n 1 )
GOSUB RemoveNthElements
ELSE
SETTEMP n = add( n 1 )
ENDIF
GOTO CheckForValidFamilySitesX
ENDIF
[RemoveNthElements]
IF m <= nFamilies
SETTEMP p = subtract( m 1 )
SET arrayelement( FamNameList p ) = arrayelement( FamNameList m )
SET arrayelement( FamPhotoList p ) = arrayelement( FamPhotoList m )
SET arrayelement( ProjNameList p ) = arrayelement( ProjNameList m )
SETTEMP m = add( m 1 )
GOTO RemoveNthElements
ENDIF
SET arrayelement( FamNameList nFamilies ) = ""
SET arrayelement( FamPhotoList nFamilies ) = ""
SET arrayelement( ProjNameList nFamilies ) = ""
SET nFamilies = subtract( nFamilies 1 )
[AskForNoWiz]
STARTWIZARD
BACKSTOP
PAGE
TYPE RADIOBUTTONS
WIZPIC wizpics\wizmagic.gif
NAME temp
DESCRIPTION The wizard has observed that you are dismissing him without using him. It will not hurt his feelings if you don't wish to have him called automatically anymore. The wizard can be available with the "Website-Homepage Expert" menu choice instead of loading automatically.\n\nDo you wish to continue loading the wizard automatically?
ARGUMENT "&Yes. Keep starting the wizard"@Yes
ARGUMENT "N&o. I will call the wizard if needed"@No
IF temp = NN
WRITEINIVALUE
ARGUMENT NN
ARGUMENT "AlwaysRunWizard"
ARGUMENT "Preferences"
MESSAGEBOX "The wizard has been dismissed. If you desire his services in the future, choose Website-Homepage Expert from the menu."